package cn.codesea.housework_user.ui.manager;

import android.content.Intent;
import android.os.Bundle;
import android.support.annotation.NonNull;
import android.support.annotation.Nullable;
import android.support.v4.app.Fragment;
import android.support.v7.widget.LinearLayoutManager;
import android.support.v7.widget.RecyclerView;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;
import android.widget.TextView;
import android.widget.Toast;

import com.google.gson.Gson;
import com.google.gson.reflect.TypeToken;

import java.lang.reflect.Type;
import java.util.ArrayList;
import java.util.List;

import butterknife.BindView;
import butterknife.ButterKnife;
import butterknife.OnClick;
import cn.codesea.housework_user.R;
import cn.codesea.housework_user.adapter.WorkerMySerListRcvAdapter;
import cn.codesea.housework_user.adapter.listener.OnRecyclerItemClickServiceListener;
import cn.codesea.housework_user.entity.Service;
import cn.codesea.housework_user.entity.ServiceVO;
import cn.codesea.housework_user.entity.Worker;
import cn.codesea.housework_user.net.ServiceGenerator;
import cn.codesea.housework_user.net.data.Result;
import cn.codesea.housework_user.net.service.WorkerService;
import cn.codesea.housework_user.ui.GuideActivity;
import cn.codesea.housework_user.ui.worker.LoginWorkerActivity;
import cn.codesea.housework_user.ui.worker.RegisterWorkerActivity;
import cn.codesea.housework_user.utils.SPUtil;
import retrofit2.Call;
import retrofit2.Callback;
import retrofit2.Response;

public class Tab3ManagerMineFragment extends Fragment {

    @BindView(R.id.logout_tv)
    TextView logout_tv;

    @Nullable
    @Override
    public View onCreateView(@NonNull LayoutInflater inflater, @Nullable ViewGroup container, @Nullable Bundle savedInstanceState) {
        View view = inflater.inflate(R.layout.fragment_tab2_mine_manager,container,false);
        ButterKnife.bind(this, view);
        return view;
    }

    @Override
    public void onActivityCreated(@Nullable Bundle savedInstanceState) {
        super.onActivityCreated(savedInstanceState);

    }

    @OnClick(R.id.logout_tv)
    public void logout_tv(){
        SPUtil.logout(getActivity());
        startActivity(new Intent(getActivity(),GuideActivity.class));
        getActivity().finish();
    }

}
